module.exports = {
    getRoomName(rooms, id) {
        return rooms.find(item => item.roomId === id).name;
    },
    getRoomMaster(rooms, id) {
        return rooms.find(item => item.roomId === id).master;
    },
    getRoomMembers(rooms, id) {
        return rooms.find(item => item.roomId === id).members;
    },
    getUserName(users, id) {
        return users.find(item => item.id === id).name;
    }
}